/**  

* <p>Title: RootConfig.java</p>  

* <p>Description: </p>  

* <p>Copyright: Copyright (c) 2017</p>  

* <p>Company: npu</p>  

* @author zhangxuhao  

* @date Nov 5, 2019  

* @version 1.0  

*/  
package cdms.config;

import java.util.regex.Pattern;

import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.ComponentScan.Filter;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.FilterType;
import org.springframework.context.annotation.Import;
import org.springframework.core.type.filter.RegexPatternTypeFilter;
import cdms.config.RootConfig.WebPackage;

/**
 * 
 * Configuration for ContextLoadListener's bean
 * 
 * @author fengduxin
 * @version 1.0
 *
 */
@Configuration
@Import(DataConfig.class)
@ComponentScan(basePackages = {"cdms"}, excludeFilters = {@Filter(type = FilterType.CUSTOM, value = WebPackage.class)})
public class RootConfig {
	
	/**
	 * scan package in cdms.web
	 */
	public static class WebPackage extends RegexPatternTypeFilter {

		public WebPackage() {
			super(Pattern.compile("cdms\\.web"));
		}
	}

}
